package ru.urfc.portal.ui.client.googlets.client.documents;

import ru.urfc.portal.ui.client.BaseDocument;
import ru.urfc.portal.ui.client.descriptor.GridDescriptor;

import com.extjs.gxt.ui.client.widget.form.TextField;
import com.google.gwt.core.client.GWT;
import com.google.gwt.uibinder.client.UiBinder;
import com.google.gwt.uibinder.client.UiField;
import com.google.gwt.user.client.ui.Widget;

public class ImportExpertise extends BaseDocument {

	interface Binder extends UiBinder<Widget, ImportExpertise> {}
	private static Binder binder = GWT.create(Binder.class);
	
	@UiField TextField<String> deviceName;
	@UiField TextField<String> platform;
	@UiField TextField<String> vendor;
	@UiField TextField<String> country;
	@UiField TextField<String> quantity;
	
	@Override
	protected void init(GridDescriptor descriptor) {
		initWidget(binder.createAndBindUi(this));

		descriptor.setAddFieldPathPrefix("data");
		descriptor.addTextField("deviceName", deviceName);
		descriptor.addTextField("platform", platform);
		descriptor.addTextField("vendor", vendor);
		descriptor.addTextField("country", country);
		descriptor.addTextField("quantity", quantity);
		descriptor.setAddFieldPathPrefix("");
	}

}
